<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;

class CreateInfSitePlayersTable extends Migration {

	/**
	 * Run the migrations.
	 *
	 * @return void
	 */
	public function up()
	{
		Schema::create('inf_site_players', function(Blueprint $table)
		{
			$table->integer('id', true);
			$table->integer('site_id')->comment('网站id');
			$table->string('username', 64)->unique('username')->comment('游戏帐号');
			$table->string('password', 64)->nullable()->comment('密码');
			$table->integer('main_game_plats_id')->comment('游戏平台');
			$table->boolean('isdemo')->default(1)->comment('1=正式帐号，0=试玩帐号，2=即时正式帐号又是试玩帐号');
			$table->timestamps();
		});
	}


	/**
	 * Reverse the migrations.
	 *
	 * @return void
	 */
	public function down()
	{
		Schema::drop('inf_site_players');
	}

}
